﻿using System.Windows.Forms;
using Deferred.Editor.Scene;
using Deferred.Library.Scene;

namespace Deferred.Editor.Gui.Scene
{
    public partial class AmbientLightPanel : UserControl
    {
        public AmbientLightPanel(AmbientLight light)
        {
            InitializeComponent();

            ambientLightWrapperBindingSource.DataSource = new AmbientLightWrapper(light);
            ambientLightBindingSource.DataSource = light;
        }

        private void wrapperUpDownValueChanged(object sender, System.EventArgs e)
        {
            ambientLightWrapperBindingSource.EndEdit();
        }
    }
}
